package com.young.shop.pojo.entity;

import java.util.List;

/**
 *	分页实体类
 */

public class Page {
	private Integer totalCount;//总记录数
	private Integer totalPage;//总页码 = 总记录数 % 每页显示条数 == 0 ？总记录数/每页显示条数 : 总记录数 / 每页显示条数 + 1
	private List<Goods> list;//每页的数据
	private Integer currentPage;//当前页码
	private Integer pageSize;//每页显示的记录数


	@Override
	public String toString() {
		return "Page{" +
				"totalCount=" + totalCount +
				", totalPage=" + totalPage +
				", list=" + list +
				", currentPage=" + currentPage +
				", pageSize=" + pageSize +
				'}';
	}

	public Page() {
	}

	public Page(Integer totalCount, Integer totalPage, List<Goods> list, Integer currentPage, Integer pageSize) {
		this.totalCount = totalCount;
		this.totalPage = totalPage;
		this.list = list;
		this.currentPage = currentPage;
		this.pageSize = pageSize;
	}

	public Integer getTotalCount() {
		return totalCount;
	}

	public void setTotalCount(Integer totalCount) {
		this.totalCount = totalCount;
	}

	public Integer getTotalPage() {
		return totalPage;
	}

	public void setTotalPage(Integer totalPage) {
		this.totalPage = totalPage;
	}

	public List<Goods> getList() {
		return list;
	}

	public void setList(List<Goods> list) {
		this.list = list;
	}

	public Integer getCurrentPage() {
		return currentPage;
	}

	public void setCurrentPage(Integer currentPage) {
		this.currentPage = currentPage;
	}

	public Integer getPageSize() {
		return pageSize;
	}

	public void setPageSize(Integer pageSize) {
		this.pageSize = pageSize;
	}
}
